﻿Imports System

Namespace System.Workflow.ComponentModel.Compiler
    <AttributeUsage((AttributeTargets.Property Or AttributeTargets.Class), AllowMultiple:=True), CLSCompliant(False)> _
    Public NotInheritable Class AttributeInfoAttribute
        Inherits Attribute
        ' Methods
        Friend Sub New(ByVal attributeInfo As AttributeInfo)
            If (attributeInfo Is Nothing) Then
                Throw New ArgumentNullException("attributeInfo")
            End If
            Me.attributeInfo = attributeInfo
        End Sub

        Friend Shared Function CreateAttributeInfoAttribute(ByVal attributeType As Type, ByVal argumentNames As String(), ByVal argumentValues As Object()) As AttributeInfoAttribute
            Return New AttributeInfoAttribute(New AttributeInfo(attributeType, argumentNames, argumentValues))
        End Function


        ' Properties
        Public ReadOnly Property AttributeInfo As AttributeInfo
            Get
                Return Me.attributeInfo
            End Get
        End Property


        ' Fields
        Private attributeInfo As AttributeInfo
    End Class
End Namespace

